import request from '@/utils/request'

export function insertExaminationActive(activeName, departmentCode, signupStartTime, signupEndTime, examStartTime,
  examEndTime, createUserId, personnelTypeName, numOfPeaple, examinationFee, remark, canOffCampusSignup, status, publishTime, filePath) {
  return request({
    url: 'exam/com.primeton.eos.teacherInfo.insertEaxminationActive.biz.ext',
    // url: '/teachers/list',
    method: 'post',
    data: {
      'activeName': activeName,
      'departmentCode': departmentCode,
      'signupStartTime': signupStartTime,
      'signupEndTime': signupEndTime,
      'examStartTime': examStartTime,
      'examEndTime': examEndTime,
      'createUserId': createUserId,
      'personnelTypeName': personnelTypeName,
      'numOfPeaple': numOfPeaple,
      'examinationFee': examinationFee,
      'remark': remark,
      'canOffCampusSignup': canOffCampusSignup,
      'status': status,
      'publishTime': publishTime,
      'modifyTime': publishTime,
      'filePath': filePath
    }
  })
}
export function queryExaminationActive(name, teacherTypeCode) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.QueryExaminationActive.biz.ext',
    method: 'post',
    data: {
      'signupTeacherCode': name,
      'teacherTypeCode': teacherTypeCode
    }
  })
}
export function signupExaminationActive(activeId, name, signupTime, teacherTypeCode) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.SignupExamination.biz.ext',
    method: 'post',
    data: {
      'activeId': activeId,
      'signupTeacherCode': name,
      'signupTime': signupTime,
      'teacherTypeCode': teacherTypeCode
    }
  })
}
export function myExaminationActive(pageSize, pageNumber, username, active_name) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.myExaminationActive.biz.ext',
    method: 'post',
    data: {
      'pageSize': pageSize,
      'pageNumber': pageNumber,
      'publishTeacherCode': username,
      'active_name': active_name
    }
  })
}
export function republishExaminationActive(id, activeName, departmentCode, signupStartTime, signupEndTime, examStartTime,
  examEndTime, createUserId, personnelTypeName, numOfPeaple, examinationFee, remark, canOffCampusSignup, status, modifyTime, filePath) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.republishExaminationActive.biz.ext',
    // url: '/teachers/list',
    method: 'post',
    data: {
      'id': id,
      'activeName': activeName,
      'departmentCode': departmentCode,
      'signupStartTime': signupStartTime,
      'signupEndTime': signupEndTime,
      'examStartTime': examStartTime,
      'examEndTime': examEndTime,
      'createUserId': createUserId,
      'personnelTypeName': personnelTypeName,
      'numOfPeaple': numOfPeaple,
      'examinationFee': examinationFee,
      'remark': remark,
      'canOffCampusSignup': canOffCampusSignup,
      'status': status,
      'modifyTime': modifyTime,
      'filePath': filePath
    }
  })
}
export function updateExaminationStatus(ids) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.updateExaminationActiveStatus.biz.ext',
    method: 'post',
    data: {
      'ids': ids
    }
  })
}
export function mySignupActive(name) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.mySignupActive.biz.ext',
    method: 'post',
    data: {
      'signupTeacherCode': name
    }
  })
}
export function myInvigilateRecords(name) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.myInvigilateRecords.biz.ext',
    method: 'post',
    data: {
      'signupTeacherCode': name
    }
  })
}
export function getSignupDetail(pageSize, pageNumber, activeId, code, name, department_code, gender, teacher_type_code) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.querySignupDetail.biz.ext',
    method: 'post',
    data: {
      'pageSize': pageSize,
      'pageNumber': pageNumber,
      'activeId': activeId,
      'code': code,
      'name': name,
      'department_code': department_code,
      'gender': gender,
      'teacher_type_code': teacher_type_code
    }
  })
}
export function updateSignupStatus(ids) {
  return request({
    url: 'exam/com.primeton.eos.ExaminationActive.updateSignupStatus.biz.ext',
    method: 'post',
    data: {
      'ids': ids
    }
  })
}

